﻿<Application x:Class="Application"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:s="clr-namespace:Stardust.Core.Controls"
    StartupUri="Window1.xaml"
ShutdownMode="OnMainWindowClose">
    <Application.Resources>
        <!-- TextBox Style -->
        <Style TargetType="{x:Type TextBox}" x:Key="TextBoxStyle">
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="Foreground" Value="BlueViolet" />
            <Setter Property="BorderBrush" Value="BlueViolet" />
        </Style>
        
        <!--ListBox Style -->
        <Style TargetType="{x:Type ListBox}" x:Key="ListBoxStyle">
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="BorderBrush" Value="Transparent" />
            <Setter Property="Foreground" Value="BlueViolet" />
        </Style>
        
        <Style TargetType="{x:Type Rectangle}" x:Key="HoverImageBackground">
            <Setter Property="Fill">
                <Setter.Value>
                    <SolidColorBrush Color="BlueViolet" />
                </Setter.Value>
            </Setter>
        </Style>
        
        <Style TargetType="{x:Type Button}" x:Key="ButtonStyle">
            <Setter Property="Foreground" Value="White" />
            <Setter Property="BorderBrush" Value="BlueViolet" />
            <Setter Property="Background">
                <Setter.Value>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="Black" Offset="0" />
                        <GradientStop Color="BlueViolet" Offset="1" />
                    </LinearGradientBrush>
                </Setter.Value>
            </Setter>
        </Style>
        
        <Style TargetType="{x:Type Grid}" x:Key="BackgroundStyle">
            <Setter Property="Background">
                <Setter.Value>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="#FFEEDDFF" Offset="0.0" />
                        <GradientStop Color="White" Offset="0.3" />
                        <GradientStop Color="White" Offset="0.8" />
                        <GradientStop Color="White" Offset="1" />
                    </LinearGradientBrush>
                </Setter.Value>
            </Setter>
        </Style>
        <Style TargetType="{x:Type Border}" x:Key="BorderStyle">
            <Setter Property="BorderBrush" Value="LightBlue" />
        </Style>
        <Style TargetType="{x:Type ComboBox}" x:Key="ComboBoxStyle">
            <Setter Property="Background">
                <Setter.Value>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="White" Offset="0.0"/>
                        <GradientStop Color="#FFF1E2FF" Offset="1" />
                    </LinearGradientBrush>
                </Setter.Value>
            </Setter>
            <Setter Property="Foreground" Value="Black" />
        </Style>
        <Style TargetType="{x:Type TextBlock}" x:Key="TextBlockStyle">
            <Setter Property="FontSize" Value="13" />
            <Setter Property="Foreground" Value="BlueViolet" />
        </Style>
        
        <Style TargetType="{x:Type TextBlock}" x:Key="LinkStyle">
            <Setter Property="TextDecorations">
                <Setter.Value>
                    <TextDecorationCollection>
                        <TextDecoration PenThicknessUnit="FontRecommended">
                            <TextDecoration.Pen>
                                <Pen Thickness="1.5" Brush="Blue">
                                    <Pen.DashStyle>
                                        <DashStyle Dashes="1"/>
                                    </Pen.DashStyle>
                                </Pen>
                            </TextDecoration.Pen>
                        </TextDecoration>
                    </TextDecorationCollection>
                </Setter.Value>
            </Setter>
            <Setter Property="Foreground" Value="Black" />
        </Style>

        <Style TargetType="{x:Type Menu}" x:Key="MenuStyle">
            <Setter Property="Background">
                <Setter.Value>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="#FFFFFFFF" Offset="0.0"/>
                        <GradientStop Color="#FFE1F0FF" Offset="1" />
                    </LinearGradientBrush>
                </Setter.Value>
            </Setter>
            <Setter Property="Opacity" Value="0.8" />
        </Style>

        <Style TargetType="{x:Type MenuItem}" x:Key="MenuItemStyle">
            <!-- <Setter Property="Background" Value="White" /> -->
        </Style>

        <Style TargetType="{x:Type Separator}" x:Key="SeparatorStyle">
            <!-- <Setter Property="Background" Value="White" /> -->
        </Style>
        
        <!-- The style of the top bar -->
        <Style TargetType="{x:Type TabItem}" x:Key="TabItemStyle">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type TabItem}">
                        <Grid>
                            <Border x:Name="TabBorder1" BorderBrush="BlueViolet"
                                    BorderThickness="1" CornerRadius="5,5,0,0">
                                <Border.Background>
                                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                                        <GradientStop Color="Black" Offset="0" />
                                        <GradientStop Color="Purple" Offset="1" />
                                    </LinearGradientBrush>
                                </Border.Background>

                                <ContentPresenter x:Name="ContentSite" VerticalAlignment="Center"
                                                  HorizontalAlignment="Center" ContentSource="Header"
                                                  Margin="3"/>
                            </Border>
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsSelected" Value="True">
                                <Setter TargetName="TabBorder1" Property="Opacity" Value="1" />
                            </Trigger>
                            <Trigger Property="IsSelected" Value="False">
                                <Setter TargetName="TabBorder1" Property="Opacity" Value="0.6" />
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="Foreground" Value="White" />
        </Style>
        
        <Style TargetType="{x:Type s:StardustButton}" x:Key="StardustButtonStyle">
            <Setter Property="Foreground" Value="White" />
            <Setter Property="BorderBrush" Value="BlueViolet" />
            <Setter Property="BackBrush">
                <Setter.Value>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="Black" Offset="0" />
                        <GradientStop Color="BlueViolet" Offset="1" />
                    </LinearGradientBrush>
                </Setter.Value>
            </Setter>
        </Style>
        
        <Style TargetType="{x:Type ProgressBar}" x:Key="ProgressBarStyle">
            <Setter Property="Background" Value="White" />
            <Setter Property="Foreground" Value="Violet" />
        </Style>
       
    </Application.Resources>
    
</Application>
